﻿@model VoiceAd.Models.tblDistrict
@using System.Data;
@using System.Linq;
@using System.Web.Mvc;
@using VoiceAd.Models;
@using VoiceAd.DAL;
@{
    ViewBag.Title = "Delete District";
    Layout = "~/Views/Shared/_LayoutAdmin.cshtml";
}
<h2>
    Delete District</h2>
<h3>
    Are you sure you want to delete this?</h3>
<fieldset>
    <legend>Thông tin</legend>
    <div class="display-label">
        Tỉnh/thành phố</div>
    <div class="display-field">
        @{
            IProvinceRepository provinceRepository = new ProvinceRepository(new dbVoiceAdDataContext());
            tblProvince tbl = provinceRepository.GetProvinceById(Convert.ToInt32(Model.ProvinceId));
            ViewBag.ProvinceName = tbl.ProvinceName;        
        }
        @Html.Raw(ViewBag.ProvinceName)
    </div>
    <div class="display-label">
        Quận/huyện</div>
    <div class="display-field">@Model.DistrictName</div>
</fieldset>
@using (Html.BeginForm())
{
    <p>
        <input type="submit" value="Delete" />
        |
        @Html.ActionLink("Back to List", "District")
    </p>
}
